package com.hust.domain;

import java.io.Serializable;

/**
 * commodity
 * @author 
 */
public class Commodity implements Serializable {
    /**
     * 自增id
     */
    private Integer id;

    /**
     * 商品唯一id,淘宝关联
     */
    private Long cId;

    /**
     * 商品描述
     */
    private String cTitle;

    /**
     * 商品类别
     */
    private String cType;

    /**
     * 商品链接
     */
    private String cUrl;

    /**
     * 商品销量
     */
    private String cSales;

    /**
     * 商品地址
     */
    private String cLocation;

    /**
     * 商品图片
     */
    private String cImage;

    /**
     * 商品热度
     */
    private Integer hot;

    /**
     * 备份字段2
     */
    private String bk2;

    private static final long serialVersionUID = 1L;

    public Integer getId() {
        return id;
    }

    public void setId(Integer id) {
        this.id = id;
    }

    public Long getcId() {
        return cId;
    }

    public void setcId(Long cId) {
        this.cId = cId;
    }

    public String getcTitle() {
        return cTitle;
    }

    public void setcTitle(String cTitle) {
        this.cTitle = cTitle;
    }

    public String getcType() {
        return cType;
    }

    public void setcType(String cType) {
        this.cType = cType;
    }

    public String getcUrl() {
        return cUrl;
    }

    public void setcUrl(String cUrl) {
        this.cUrl = cUrl;
    }

    public String getcSales() {
        return cSales;
    }

    public void setcSales(String cSales) {
        this.cSales = cSales;
    }

    public String getcLocation() {
        return cLocation;
    }

    public void setcLocation(String cLocation) {
        this.cLocation = cLocation;
    }

    public String getcImage() {
        return cImage;
    }

    public void setcImage(String cImage) {
        this.cImage = cImage;
    }

    public Integer getHot() {
        return hot;
    }

    public void setHot(Integer hot) {
        this.hot = hot;
    }

    public String getBk2() {
        return bk2;
    }

    public void setBk2(String bk2) {
        this.bk2 = bk2;
    }

    @Override
    public boolean equals(Object that) {
        if (this == that) {
            return true;
        }
        if (that == null) {
            return false;
        }
        if (getClass() != that.getClass()) {
            return false;
        }
        Commodity other = (Commodity) that;
        return (this.getId() == null ? other.getId() == null : this.getId().equals(other.getId()))
            && (this.getcId() == null ? other.getcId() == null : this.getcId().equals(other.getcId()))
            && (this.getcTitle() == null ? other.getcTitle() == null : this.getcTitle().equals(other.getcTitle()))
            && (this.getcType() == null ? other.getcType() == null : this.getcType().equals(other.getcType()))
            && (this.getcUrl() == null ? other.getcUrl() == null : this.getcUrl().equals(other.getcUrl()))
            && (this.getcSales() == null ? other.getcSales() == null : this.getcSales().equals(other.getcSales()))
            && (this.getcLocation() == null ? other.getcLocation() == null : this.getcLocation().equals(other.getcLocation()))
            && (this.getcImage() == null ? other.getcImage() == null : this.getcImage().equals(other.getcImage()))
            && (this.getHot() == null ? other.getHot() == null : this.getHot().equals(other.getHot()))
            && (this.getBk2() == null ? other.getBk2() == null : this.getBk2().equals(other.getBk2()));
    }

    @Override
    public int hashCode() {
        final int prime = 31;
        int result = 1;
        result = prime * result + ((getId() == null) ? 0 : getId().hashCode());
        result = prime * result + ((getcId() == null) ? 0 : getcId().hashCode());
        result = prime * result + ((getcTitle() == null) ? 0 : getcTitle().hashCode());
        result = prime * result + ((getcType() == null) ? 0 : getcType().hashCode());
        result = prime * result + ((getcUrl() == null) ? 0 : getcUrl().hashCode());
        result = prime * result + ((getcSales() == null) ? 0 : getcSales().hashCode());
        result = prime * result + ((getcLocation() == null) ? 0 : getcLocation().hashCode());
        result = prime * result + ((getcImage() == null) ? 0 : getcImage().hashCode());
        result = prime * result + ((getHot() == null) ? 0 : getHot().hashCode());
        result = prime * result + ((getBk2() == null) ? 0 : getBk2().hashCode());
        return result;
    }

    @Override
    public String toString() {
        StringBuilder sb = new StringBuilder();
        sb.append(getClass().getSimpleName());
        sb.append(" [");
        sb.append("Hash = ").append(hashCode());
        sb.append(", id=").append(id);
        sb.append(", cId=").append(cId);
        sb.append(", cTitle=").append(cTitle);
        sb.append(", cType=").append(cType);
        sb.append(", cUrl=").append(cUrl);
        sb.append(", cSales=").append(cSales);
        sb.append(", cLocation=").append(cLocation);
        sb.append(", cImage=").append(cImage);
        sb.append(", hot=").append(hot);
        sb.append(", bk2=").append(bk2);
        sb.append(", serialVersionUID=").append(serialVersionUID);
        sb.append("]");
        return sb.toString();
    }
}